<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
 <head>
  <meta charset="UTF-8">
  <meta name="Generator" content="EditPlus®">
  <meta name="Author" content="">
  <meta name="Keywords" content="">
  <meta name="Description" content="">
  <title>Document</title>
  <link rel="stylesheet" href="/xyq/with/Public/admin/Css/public.css">
  <script type="text/javascript" src="/xyq/with/Public/Admin/Js/jquery-1.7.2.min.js"></script>
    <script type="text/javascript" src="/xyq/with/Public/Admin/Js/wish.js"></script>
      <style type="text/css">
          body{
              margin: 20px 100px;;
          }
          h2{
              color:  #0b99d8;
              font-size: 40px;
              text-align:center;
          }
          .table tr th{
              background-color:  #0b99d8;
          }
         a.num,a.prev,a.next,a.first,a.end,span.current{
              display: block;
              padding: 10px 10px;
              float: left;
              border: 2px #2b66a5 solid;
              margin: 3px 5px;
              
          }
          span.current{
              background-color:#2b66a5;
              color: white;
          }
          div{
              margin: 0 auto;
              width: 300px;
              height: 30px;
          }
          .table tr th,td{
              text-align:center;
          }
          #search{
              height: 30px;
              width: 600px;
          }
      </style>
 </head>
 <body>
     <h2>愿望列表</h2>
     <form method="get">
            <div id="search">
                 请输入查询关键字：
                 <input type="text" name="sname" value="<?php echo ($sname); ?>"></input>
                 <select name="sop">
                     <option 
                         <?php if(($sop) == "1"): ?>selected="selected"<?php endif; ?>
                          value="1">按发布者名字查询</option>
                     <option <?php if(($sop) == "1"): ?>selected="selected"<?php endif; ?> value="2">按发布内容查询</option>
                 </select>
                 <input type="submit" value="搜索"></input>
            </div>
     </form>
     <form action="<?php echo U('Admin/WishManage/muldel');?>" method="post">
         <table class="table" id="list">
		<tr>    <th style="width: 5%"><input type="checkbox" id="all"></input></th>
			<th style="width: 5%">ID</th>
			<th style="width: 10%">发布者</th>
			<th>内容</th>
			<th style="width: 15%">发布时间</th>
			<th style="width: 5%">操作</th>
		</tr>

		<?php if(is_array($wish)): foreach($wish as $key=>$v): ?><tr>    
                            <td><input type="checkbox" value="<?php echo ($v["id"]); ?>" name="cboxdel[]"></input></td>
				<td><?php echo ($v["id"]); ?></td>
				<td><?php echo ($v["name"]); ?></td>
				<td><?php echo ($v["content"]); ?></td>
				<td><?php echo (date('y-m-d H:i',strtotime($v["addtime"]))); ?></td>
				<td><a href="<?php echo U('Admin/WishManage/del',array('id' => $v['id'])),'';?>">删除</a></td>
			</tr><?php endforeach; endif; ?>
            <div>
                <tr>
			<td colspan='6' align='center'>
				<?php echo ($page); ?>
			</td>
		</tr>
                <tr  colspan='6' align='center'>
                    <input type="submit" value="删除所选"></input>
                </tr>
            </div>
	</table>
  </form>
 </body>
</html>